import * as echarts from 'echarts/core';
const ldTrendChartOpt = {
    data() {
        return {
            ldTrendChartOpt: {
                backgroundColor: '#ffffff',
                textStyle: {
                    color: 'black'
                },
                grid: {
                    top: '10%',
                    left: "17%",
                    right: '0%',
                    bottom: '7%',
                },
                dataZoom: [

                    {
                        type: 'inside',
                        xAxisIndex: [0],
                        start: 1,
                        end: 40,
                        zoomLock: true, //锁定区域禁止缩放
                    },

                ],
                tooltip: {
                    trigger: 'axis',
                    axisPointer: {
                        type: 'shadow'
                    },
                    formatter:function(val){
                        var txt = val[0].name;
                        return val[0].name+"<br>"+val[0].marker+'最高温&ensp;&ensp;'+val[0].value+"℃<br>"+
                        val[1].marker+'实时温度'+val[1].value+"℃<br>"+
                        val[2].marker+'最低温&ensp;&ensp;'+val[2].value+"℃";
                    }
                },
                xAxis: {
                    type: 'category',
                    axisLine: {
                        lineStyle: {
                            color: '#ccc'
                        }
                    },
                    axisTick: {
                        show: false // 不显示 y 轴刻度线
                    },
                    splitLine: {
                        show: false // 去掉 y 轴上的分隔线
                    },
                    data: []
                },
                yAxis: {
                    type: 'value',
                    axisLabel: {
                        formatter: '{value} °C',
                    },
                    axisLine: {
                        lineStyle: {
                            color: '#ccc'
                        }
                    },
                    splitLine: { show: false },
                    // axisLine: {
                    //     show: true,
                    // },
                },
                series: [
                     {
                        name: 'bar',
                        type: 'line',
                        smooth: true,
                        showAllSymbol: true,
                        symbol: 'emptyCircle',
                        symbolSize: 8,
                        symbolOffset: 0,
                        data: [],

                        label:{
                            show: true
                        }
                    }, {
                        name: 'bar',
                        type: 'line',
                        smooth: true,
                        showAllSymbol: true,
                        symbol: 'emptyCircle',
                        symbolSize: 8,
                        symbolOffset: 0,
                        data: [],

                        label:{
                            show: true
                        }
                    }, {
                        name: 'three',
                        type: 'line',
                        smooth: true,
                        showAllSymbol: true,
                        symbol: 'emptyCircle',
                        symbolSize: 8,
                        symbolOffset: 0,
                        data: [],
                        label:{
                            show: true
                        }
                    }
                ]
            }
            
        }
    },
    mounted() {

    },
    components: {

    },
    methods: {

    }
}
export default ldTrendChartOpt;